<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      const info = {
        height: 300,
        width: 300,
        color: "green",
      };
      // const { ...newInfo } = info;
      // const newInfo = Object.fromEntries(Object.entries(info));
      const newInfo = Object.assign({}, info);
      console.log(newInfo);
    </script>
  </body>
</html>
